package com.bvgol.examples.springbootmybatisplus.mutipleDataSources.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
 * @Classname Book
 * @Description TODO
 * @Date 2021/4/23 11:33
 * @Created by GUOCHEN
 */
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "Book")
public class Book implements Serializable {
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 作者信息
     */
    @TableField(value = "author")
    private String author;

    /**
     * 书籍名称
     */
    @TableField(value = "name")
    private String name;

    /**
     * 价格
     */
    @TableField(value = "price")
    private Long price;

    /**
     * 上架时间
     */
    @TableField(value = "createTime")
    private Date createtime;

    /**
     * 书籍描述
     */
    @TableField(value = "description")
    private String description;

    private static final long serialVersionUID = 1L;
}
